<div id="top"><a href="blog-main.php"><img src="images/logo.gif" width="239" height="51" /></a>
  <ul>
    <li><a href="loginout.php">登出系統</a></li>
    <?php if($_SESSION['PRI_ADMIN'] == '1'):?>
    <li><a href="admin-ip.php">來源IP查詢</a></li>
    <?php endif;?>
    
	<?php if($_SESSION["PRI_ADMIN"]==1 || $_SESSION["PRI_EDIT"]==1){?>
    <li><a href="admin_manage.php">帳號管理</a></li>
	<?php }else{?>
	 <li><a href="admin_password.php?id=<?php echo $_SESSION["id2"];?>&username=<?php echo $_SESSION["username2"];?>">個人帳號管理</a></li>
	<?php }?>
	
	<?php if($_SESSION['PRI_ADMIN'] == '1' || $_SESSION['PRI_SALE'] == '1' ):?>
	<li><a href="ad-sale-main.php">廣告管理</a></li>
	<?php endif;?>
	<?php if($_SESSION['PRI_ADMIN'] == '1'):?>
	<li><a href="blog-main-lock.php">文章鎖定</a></li>
	<?php endif;?>
	<?php if($_SESSION['PRI_ADMIN'] == '1' || $_SESSION['PRI_EDIT'] == '1'):?>
	<li><a href="blog-main.php">文章管理</a></li>
	<?php endif;?>
	<?php if($_SESSION['PRI_ADMIN'] == '1'):?>
    <li><a href="admin-index.php">首頁管理</a></li>
    <?php endif;?>
    <li>主功能列表</li>
  </ul>
  </div>